{% extends "pydata_sphinx_theme/layout.html" %}


{%- block htmltitle %}
{% if pagename == "index" %}
<title>pymoo: Multi-objective Optimization in Python</title>
{% else %}
<title>pymoo - {{ title|e }}</title>
{% endif %}
{%- endblock %}

{% block docs_sidebar %}
{% endblock %}


{# prev/next buttons #}
{% macro my_prev_next(prev, next, prev_title='', next_title='') %}
{%- if prev %}
<div class="col text-left my-auto">
    <a href="{{ prev.link|e }}">
        <button type="button" href="{{ prev.link|e }}"
                class="text-left prev-next-link left-prev btn btn-outline-secondary"><< {{
            prev_title or prev.title }}
        </button>
    </a>
</div>
{%- endif %}

{%- if next %}
<div class="col text-right my-auto">
    <a href="{{ next.link|e }}">
        <button type="button" class="text-right prev-next-link right-next btn btn-outline-secondary">{{
            next_title or next.title }} >>
        </button>
    </a>
</div>
{%- endif %}
{% endmacro %}


{%- block css %}
{{ super() }}
<link rel="stylesheet" href="{{ pathto('_static/css/custom.css', 1) }}">
<link rel="stylesheet" href="{{ pathto('_static/css/pure.css', 1) }}">
<link rel="icon" type="image/png" href="{{ pathto('_static/favicon.ico', 1) }}"/>
{%- endblock %}

{%- block js %}
{{ super() }}

{%- endblock %}


{% set is_single_page = (theme_single_page == True) or (theme_single_page == "True") %}
{% if is_single_page %}
{%- set sidebar_width_class = "col-md-2" %}
{% else %}
{%- set sidebar_width_class = "col-md-3" %}
{% endif %}

{% block extrahead %}
{{ super() }}

    <script async src="https://www.googletagmanager.com/gtag/js?id=G-E228X7JZK9"></script>
    <script>
      window.dataLayer = window.dataLayer || [];
      function gtag(){dataLayer.push(arguments);}
      gtag('js', new Date());
      gtag('config', 'G-E228X7JZK9');
    </script>

    {% if pageurl %}
        <!-- Opengraph tags -->
        <meta property="og:url" content="{{ pageurl }}"/>
        <meta property="og:type" content="article"/>
        <meta property="og:title" content="{% if pagetitle %}{{ pagetitle | e }}{% else %}{{ docstitle | e }}{% endif %}"/>
        <meta property="og:description" content="{{ page_description | e }}"/>
        {% if logourl %}
        <meta property="og:image" content="{{ logourl }}"/>{% endif %}
        <meta name="twitter:card" content="summary"/>
    {% endif %}
{% endblock %}


{% block docs_main %}
{%- include "newsletter.html" %}
<main id="my-wrapper" class="container-xl mx-auto p-0 m-0 mt-3 mb-1 bd-content" role="main">


    {% block docs_body %}

    <!--    <div class="w-25 p-3" style="background-color: #eee;">Width 25%</div>-->


    <div id="main-header" class="row no-gutters">
        <div class="col-12">
            <a href="{{ pathto('index.html', 1) }}">
                <img class="img-header d-none d-md-block" alt="header" src="{{ pathto('_static/header.jpg', 1) }}">
                <img class="img-header d-block d-md-none" alt="header" src="{{ pathto('_static/logo.svg', 1) }}">
            </a>
        </div>
    </div>

    <div id="main-topbar" class="row m-0 px-3 py-3 border-bottom sticky">
        {% include "topbar.html" %}
    </div>

    <div class="row m-0 pt-1 px-3">

        <div id="main-navbar" class="col-12 col-md-3 bd-sidebar sticky show" role="menu">
            {% include "search-field.html" %}
            {% include "sbt-sidebar-nav.html" %}
        </div>


        <div id="main-content" class="col py-3 px-6 col-md-9 px-md-4">

            <div>
                {{ super() }}
            </div>

            {% if theme_show_prev_next %}
            <div class='row prev-next-bottom mt-5 mb-2 px-0 h-auto'>
                {{ my_prev_next(prev, next) }}
            </div>
            {% endif %}

        </div>


{#        <div id="main-toc" class="d-none d-md-block col-md-2 pl-0 bd-toc sticky show">#}
{#            {{ generate_toc_html() }}#}
{#        </div>#}

    </div>

    <div id="main-footer" class="row">
        {%- include "footer.html" %}
    </div>



</main>
{% endblock %}

</div>
{% endblock %}

{% block docs_toc %}
{% endblock %}

{% block docs_navbar %}
{%- endblock %}

{%- block footer %}
{%- endblock %}
